import React, { memo } from 'react';
import styles from './index.less';
import { IButtonConfig } from './schema';
import { Button as AntdButton } from 'antd';

const Button = memo((props: IButtonConfig) => {
  const { height, text } = props;
  return (
    <div className={styles.buttonWrap}>
      <AntdButton style={{ height: height + 'px' }}>{text}</AntdButton>
    </div>
  );
});

export default Button;
